<?php
namespace app\common\validate;

use think\Validate;

class UserId extends Validate
{
    protected $rule = [
        'ID_num|身份证号码'  =>  'require|IDCard',
        'real_name|姓名'  =>  'require|chs|max:12',
        'face|身份证正面照'  =>  'require',
        'back|身份证反面照'  =>  'require',
        'img|识别照'  =>  'require',
    ];


    /**
     * 身份证号码验证
     */
    protected function IDCard($value)
    {
        return IDCard($value);
    }
}